package com.intretech.umsin.system.api;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.intretech.umsin.common.web.ApiResult;
import com.intretech.umsin.system.param.SysUserRoleParam;
import com.intretech.umsin.system.vo.SysUserRoleVo;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
* @version V1.0
* 用户和角色关联: sys_user_role 为其他服务提供内部调用接口 API.
* @InterfaceName: SysUserRoleApi
* @Description: 用户和角色关联:sys_user_role 为其他服务提供内部调用接口 API.
* @author: 李启联
* @date:   2022-8-16 16:44:08
* @Copyright: Copyright (c) 2022
*/

public interface SysUserRoleApi {

    @GetMapping("/system/sysuserrole/get/{id}")
    public ApiResult<SysUserRoleVo> querySysUserRoleById(@PathVariable("id") String id);

    @PostMapping("/system/sysuserrole/listByIds")
    public ApiResult<List<SysUserRoleVo>> querySysUserRoleByIds(@RequestBody List<String> ids);

    @PostMapping("/system/sysuserrole/page/{pageNo}/{pageSize}")
    public ApiResult<IPage<SysUserRoleVo>> querySysUserRoleForPage(@RequestBody SysUserRoleParam params, @PathVariable("pageNo") Integer pageNo, @PathVariable("pageSize") Integer pageSize);

    @PostMapping("/system/sysuserrole/list")
    public ApiResult<List<SysUserRoleVo>> querySysUserRoleForList(@RequestBody SysUserRoleParam params);

    @PostMapping("/system/sysuserrole/add")
    public ApiResult<SysUserRoleVo> addSysUserRole(@RequestBody SysUserRoleVo vo);

    @PostMapping("/system/sysuserrole/adds")
    public ApiResult<List<SysUserRoleVo>> addsSysUserRole(@RequestBody List<SysUserRoleVo> voList);

    @PutMapping("/system/sysuserrole/modify")
    public ApiResult<SysUserRoleVo> modifySysUserRole(@RequestBody SysUserRoleVo vo);

    @PutMapping("/system/sysuserrole/modifys")
    public ApiResult<List<SysUserRoleVo>> modifysSysUserRole(@RequestBody List<SysUserRoleVo> voList);

    @DeleteMapping("/system/sysuserrole/remove/{id}")
    public ApiResult<Void> removeSysUserRole(@PathVariable("id") String id);

    @DeleteMapping("/system/sysuserrole/removes")
    public ApiResult<Void> removesSysUserRole(@RequestBody List<String> ids);



}